package br.com.honorato.util.dao;

import java.util.Arrays;
import java.util.List;

public enum ETypeLike
{
	INIT("%#"), END("#%"), BOTH("%#%");

	private final String code;

	private ETypeLike(String code)
	{
		this.code = code;
	}

	public String getCode()
	{
		return this.code;
	}

	public static List<ETypeLike> getListValues()
	{
		return Arrays.asList(ETypeLike.values());
	}

	public static ETypeLike getEModuleType(String code)
	{
		for (ETypeLike eModuleType : getListValues())
		{
			if (eModuleType.getCode().equalsIgnoreCase(code))
			{
				return eModuleType;
			}
		}
		return null;
	}
}